define(function (require, exports, module) {  
    var SearchTable = React.createClass({
        getInitialState: function () {
            return {};
        },
        render: function () {
            var data = this.props.data; 
            var header = [];      
            var body = [];
            header = (
                <tr><th></th><th>标题</th><th>文档位置</th><th>拥有者</th><th>时间</th></tr>
                )
            if (data) {
                var _this = this;
                _.each(data, function (node) {
                    body.push(<tr>
                            <td><i className="fa fa-file-text-o"></i></td>
                            <td><a href="#">{node.name}</a></td>
                            <td><a href="#">{node.path}</a></td>
                            <td><a href="#">{node.owner}</a></td>
                            <td><a href="#">{node.time}</a></td>
                            </tr>
                             )
                    body.push(<tr>
                            <td></td>
                            <td colSpan ="4" className="bg_f5">{node.description}</td>                       
                            </tr>)
                });
            }
            var classes = {
                'table' : true,
                'table-hover' : true
            }
            var table = (
                <table className = {classNames(classes)}>
                 <thead>{header}</thead>
                 <tbody>{body}</tbody>             
                </table>
                )    
            return (
                <div className = "table-responsive">            
                    {table}
                </div>
            )
        }
    });
    return SearchTable;
})